package com.changjiang.luban.utils.result;

import lombok.Data;

import java.io.Serializable;

/**
 * Created with IntelliJ IDEA.
 * Description:文件上传返回结果封装
 *
 * @author changjiang
 * Date: 2018-04-06
 * Time: 16:54
 */
@Data
public class FileUploadResult implements Serializable {

    private static final long serialVersionUID = 4943771376100630626L;

    /**
     * 错误状态码
     * O表示满意错误
     */
    private Integer error;

    /**
     * 返回上传成功的图片路径地址
     */
    private String[] data;

    public static FileUploadResult success(String[] url){
        FileUploadResult result = new FileUploadResult();
        result.setError(0);
        result.setData(url);
        return result;
    }


}
